<template>
  <div id="loadingModal">
    <div id="loadingBack">
      <!--<img src="https://static.idoupiao.com/icbcfilm/pro/loading.gif" id="loadingIcon"/>-->
    </div>
  </div>
</template>
<style scoped>
  #loadingModal {
    background-color: rgba(0, 0, 0, 0.5);
    width: 100%;
    height: 100%;
    position: fixed;
    top: 0;
    z-index: 10001;
  }

  #loadingBack {
    position: fixed;
    padding: 10px;
    border-radius: 10px;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    /*background-color: rgba(50, 50, 50, 0.5);*/
  }

  #loadingIcon {
    /*background-image: url('~svg/loading.svg');*/
    background-size: contain;
    width: 60px;
  }
</style>
<script>
  export default{
    name: 'loading',
    data(){
      return {};
    },
    props: {
      showLoading: {
        type: Boolean,
        default() {
          return false
        }
      }
    },
    components: {},
    methods: {},
    mounted: function () {
      document.querySelector('body').style.overflow = 'hidden';
    },
    beforeDestroy: function () {
      document.querySelector('body').style.overflow = 'auto';
    }
  };
</script>
